@extends('layout.admin.index')
<?php  $left_selected="权限管理"; $center_selected = "分配节点"; ?>

@section('main')
<div class="mws-panel grid_8">
    <div class="mws-panel-header">
        <span>分配节点</span>
    </div>

    @if (count($errors) > 0)
          <div class="mws-form-message error">
            <ul>
                @foreach ($errors->all() as $error)
                    <li>{{ $error }}</li>
                @endforeach
            </ul>
        </div>
    @endif

    <div class="mws-panel-body no-padding">
        <form action="{{route('distri.saveNode')}}" method="post" class="mws-form">
           <div class="mws-form-row">
                <label class="mws-form-label">节点名称</label>
                <div class="mws-form-item clearfix">
                    <ul class="mws-form-list inline">

                <input type="hidden" name="rId" value="{{ $rId }}"/>
            @foreach($node as $k => $v)
            @if($k%5==0)
             <br>
             @endif
              <input type="checkbox" name="rNid[]" value="{{ $v->id }}" {{ in_array($v->id,$rNid)?"checked":"" }}> {{ $v->username }}    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
             
            @endforeach 

                       
                    </ul>
                </div>
            </div>

                
            <div class="mws-button-row">
                {{ csrf_field() }}
                <input type="submit" class="btn btn-danger" value="保存">
                <input type="reset" class="btn " value="重置">
            </div>
        </form>
    </div>
</div>
@endsection









